home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / idl / nsISVGRendererPathBuilder.idl < prev    next >
Text File  |  2006-05-08  |  5KB  |  125 lines

  1. /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /* ***** BEGIN LICENSE BLOCK *****
  3.  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
  4.  *
  5.  * The contents of this file are subject to the Mozilla Public License Version
  6.  * 1.1 (the "License"); you may not use this file except in compliance with
  7.  * the License. You may obtain a copy of the License at
  8.  * http://www.mozilla.org/MPL/
  9.  *
  10.  * Software distributed under the License is distributed on an "AS IS" basis,
  11.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  12.  * for the specific language governing rights and limitations under the
  13.  * License.
  14.  *
  15.  * The Original Code is the Mozilla SVG project.
  16.  *
  17.  * The Initial Developer of the Original Code is
  18.  * Crocodile Clips Ltd.
  19.  * Portions created by the Initial Developer are Copyright (C) 2002
  20.  * the Initial Developer. All Rights Reserved.
  21.  *
  22.  * Contributor(s):
  23.  *   Alex Fritze <alex.fritze@crocodile-clips.com> (original author)
  24.  *
  25.  * Alternatively, the contents of this file may be used under the terms of
  26.  * either of the GNU General Public License Version 2 or later (the "GPL"),
  27.  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
  28.  * in which case the provisions of the GPL or the LGPL are applicable instead
  29.  * of those above. If you wish to allow use of your version of this file only
  30.  * under the terms of either the GPL or the LGPL, and not to allow others to
  31.  * use your version of this file under the terms of the MPL, indicate your
  32.  * decision by deleting the provisions above and replace them with the notice
  33.  * and other provisions required by the GPL or the LGPL. If you do not delete
  34.  * the provisions above, a recipient may use your version of this file under
  35.  * the terms of any one of the MPL, the GPL or the LGPL.
  36.  *
  37.  * ***** END LICENSE BLOCK ***** */
  38.  
  39. #include "nsISupports.idl"
  40.  
  41. /**
  42.  * \addtogroup renderer_interfaces Rendering Engine Interfaces
  43.  * @{
  44.  */
  45.  
  46. /**
  47.  * One of a number of interfaces (all starting with nsISVGRenderer*)
  48.  * to be implemented by an SVG rendering engine. See nsISVGRenderer
  49.  * for more details.
  50.  *
  51.  * This interface is used by an nsISVGRendererPathGeometry object in
  52.  * a call to nsISVGPathGeometrySource::constructPath() to obtain a
  53.  * native representation of the path described by
  54.  * nsISVGPathGeometrySource.
  55.  */
  56. [scriptable, uuid(c3cd294e-39ae-4718-b2bc-87c0fad97a12)]
  57. interface nsISVGRendererPathBuilder : nsISupports
  58. {
  59.   /**
  60.    * Move current position and start new sub-path.
  61.    *
  62.    * @param x X-coordinate (untransformed).
  63.    * @param y Y-coordinate (untransformed).
  64.    */
  65.   void moveto(in float x, in float y);
  66.  
  67.   /**
  68.    * Draw a straight line from the current position to (x,y). Advance
  69.    * current position to (x,y).
  70.    *
  71.    * @param x X-coordinate of end point (untransformed).
  72.    * @param y Y-coordinate of end point (untransformed).
  73.    */
  74.   void lineto(in float x, in float y);
  75.  
  76.   /**
  77.    * Draw cubic Bezier curve from the current position to (x,y) using
  78.    * (x1,y1) as the control point at the beginning og the curve and
  79.    * (x2,y2) as the control point at the end of the curve. Advance
  80.    * current position to (x,y).
  81.    *
  82.    * @param x  X-coordinate of end point (untransformed).
  83.    * @param y  Y-coordinate of end point (untransformed).
  84.    * @param x1 X-coordinate of first control point (untransformed).
  85.    * @param y1 Y-coordinate of first control point (untransformed).
  86.    * @param x2 X-coordinate of second control point (untransformed).
  87.    * @param y2 Y-coordinate of second control point (untransformed).
  88.    */
  89.   void curveto(in float x, in float y, in float x1, in float y1, in float x2, in float y2);
  90.  
  91.   /**
  92.    * Draw an elliptical arc from the current position to
  93.    * (x,y). Advance current position to (x,y).
  94.    *
  95.    * @param x            X-coordinate of end point (untransformed).
  96.    * @param y            Y-coordinate of end point (untransformed).
  97.    * @param r1           Radius of ellipse in X direction (untransformed).
  98.    * @param r2           Radius of ellipse in Y direction (untransformed).
  99.    * @param angle        Rotation of ellipse as a whole (untransformed).
  100.    * @param largeArcFlag PR_TRUE: choose the large arc (>=180 degrees),
  101.    *                     PR_FALSE: choose the smaller arc (<=180 degrees)
  102.    * @param sweepFlag    PR_TRUE: sweep in positive angle direction,
  103.    *                     PR_FALSE: sweep in negative angle direction
  104.    */
  105.   void arcto(in float x, in float y, in float r1, in float r2, in float angle,
  106.              in boolean largeArcFlag, in boolean sweepFlag);
  107.  
  108.   /**
  109.    * Close the current subpath. Move current position back to
  110.    * beginning of subpath.
  111.    *
  112.    * @param newX X-coordinate of new current position (untransformed).
  113.    * @param newY Y-coordinate of new current position (untransformed).
  114.    */
  115.   void closePath(out float newX, out float newY);
  116.  
  117.   /**
  118.    * End the path description. Guaranteed to be the last function
  119.    * called.
  120.    */
  121.   void endPath();
  122. };
  123.  
  124. /** @} */
  125.